package com.cqsd.bean.beantest;

import com.cqsd.ioc.annotation.Component;

import java.util.StringJoiner;

/**
 * @author caseycheng
 * @date 2023/3/27-17:37
 **/
@Component
public class Stu {
    private final Person person;

    public Stu(Person person) {
        this.person = person;
        System.out.println(this);
    }

    @Override
    public String toString() {
        return new StringJoiner(", ", Stu.class.getSimpleName() + "[", "]")
                .add("person=" + person)
                .toString();
    }
}
